import Vue from 'vue'
import App from './App.vue'
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import router from './router'
import store from './store'
import axios from '@/assets/js/axios'
import VCharts from 'v-charts'
Vue.prototype.$axios = axios
Vue.use(VCharts)
Vue.prototype.$api = ''
//Vue.prototype.$api = process.env.VUE_APP_API
Vue.prototype.$imgUrl = process.env.VUE_APP_IMGURL
Vue.prototype.$qrUrl = process.env.VUE_APP_QRURL


//Vue.prototype.$api = 'http://admin.youjingxi.net.cn'
/* Vue.prototype.$imgUrl = 'http://admin.youjingxi.net.cn/uploads/'
Vue.prototype.$qrUrl = 'http://admin.youjingxi.net.cn/code/' */
Vue.use(ElementUI);

Vue.prototype.$goTop = () => {
  // chrome
  document.body.scrollTop = 0
  // firefox
  document.documentElement.scrollTop = 0
  // safari
  window.pageYOffset = 0
}

Vue.config.productionTip = false

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
